package track;

import io.DbFuncs;

/**
 * This is the artist for the tracks
 * 
 * @author Alex
 *
 */
public class Artist {

	private int _id;
	private String _name = null;
	
	public Artist(int id)
	{
		this._id = id;
	}
	
	public Artist(int id, String name)
	{
		this(id);
		this._name = name;
	}
	
	/**
	 * All the get functions
	 * 
	 * @return int
	 */
	public int getId()
	{
		return this._id;
	}
	/**
	 * @return String
	 */
	public String getName()
	{
		if(this._name == null)
			this._name = DbFuncs.getContentString("artists", "name", "id", this._id);
		
		return this._name;
	}

	public void setName(String fixS) {
		this._name = fixS;
		
	}
}
